<template>
	<view class="container">
		<view class="text-area">
			<text>输入值：</text>
			<input type="text" v-model="title" class="input-red" />
		</view>
		<view class="text-area">
			<text>回传值：</text>
			<input type="text" :value="callBackValue" class="input-yellow" />
		</view>
		<ComAView :intent="title"></ComAView>
		<ComBView @callBackFun="callBack"></ComBView>
	</view>
</template>

<script>
	import ComAView from '../../components/ComAView.vue';
	import ComBView from '../../components/ComBView.vue';

	export default {
		components:{
			ComAView,ComBView
		},
		data() {
			return {

			}
		},
		methods: {
			callBack(msg) {
			  console.warn("---index---callBack--> " + msg);
			  this.callBackValue = msg;
			}
		}
	}
</script>

<style>
	.container {
		padding-top: 100rpx;
	}

	.text-area {
		margin-bottom: 20rpx;
		font-size: 32rpx;
	}

	.input-red {
		color: red;
		border: 1px solid #ff5500;
		padding: 10rpx;
		width: 300rpx;
	}

	.input-yellow {
		color: yellow;
		border: 1px solid #ff5500;
		padding: 10rpx;
		width: 300rpx;
	}
</style>